import { NgModule } from '@angular/core';
import { BrowserModule } from '@angular/platform-browser';

import { AppRoutingModule } from './app-routing.module';
import { AppComponent } from './app.component';
import { NZ_I18N } from 'ng-zorro-antd/i18n';
import { zh_CN } from 'ng-zorro-antd/i18n';
import { registerLocaleData } from '@angular/common';
import zh from '@angular/common/locales/zh';
import { FormsModule, ReactiveFormsModule } from '@angular/forms';
// 如果需要用到jsonp解决跨域请求问题，还需要引入HttpClientJsonpModule
import { HttpClientModule, HttpClientJsonpModule } from '@angular/common/http';
import { BrowserAnimationsModule } from '@angular/platform-browser/animations';



// 引入组件
import { NzButtonModule } from 'ng-zorro-antd/button';
import { NzSliderModule } from 'ng-zorro-antd/slider';
import { NzInputNumberModule } from 'ng-zorro-antd/input-number';
import { NzGridModule } from 'ng-zorro-antd/grid';
import { NzDrawerModule } from 'ng-zorro-antd/drawer';
import { NzIconModule } from 'ng-zorro-antd/icon';
import { NzTableModule } from 'ng-zorro-antd/table';
import { NzDividerModule } from 'ng-zorro-antd/divider';
import { NzPopconfirmModule } from 'ng-zorro-antd/popconfirm';
import { NzModalModule } from 'ng-zorro-antd/modal';
import { NzFormModule } from 'ng-zorro-antd/form';
import { NzInputModule } from 'ng-zorro-antd/input';
// import { FormsModule, ReactiveFormsModule} from '@angular/forms';
import { NzSelectModule } from 'ng-zorro-antd/select';
import { NzDatePickerModule } from 'ng-zorro-antd/date-picker';
import { NzUploadModule } from 'ng-zorro-antd/upload';
import { NzImageModule } from 'ng-zorro-antd/image';


// 页面
import { HomeComponent } from './home/home.component';
import { Demo01Component } from './demo01/demo01.component';
import { Demo02Component } from './demo02/demo02.component';
import { DemoBese64Component } from './demo-bese64/demo-bese64.component';
import { GetGlobalComponent } from './get-global/get-global.component';
import { DemoLocalStorageComponent } from './demo-local-storage/demo-local-storage.component';
import { SliderLabelComponent } from './slider-label/slider-label.component';
import { DemoWsComponent } from './demo-ws/demo-ws.component';
import { DemoMasterComponent } from './demo-master/demo-master.component';
import { TestDataComponent } from './test-data/test-data.component';
import { CanvasPdfComponent } from './canvas-pdf/canvas-pdf.component';
import { ScreenRecordingComponent } from './screen-recording/screen-recording.component';
import { Demo4Component } from './demo-4/demo-4.component';
import { Demo5Component } from './demo-5/demo-5.component';

registerLocaleData(zh);

@NgModule({
  declarations: [
    AppComponent,
    HomeComponent,
    Demo01Component,
    Demo02Component,
    DemoBese64Component,
    GetGlobalComponent,
    DemoLocalStorageComponent,
    SliderLabelComponent,
    DemoWsComponent,
    DemoMasterComponent,
    TestDataComponent,
    CanvasPdfComponent,
    ScreenRecordingComponent,
    Demo4Component,
    Demo5Component,
  ],
  // 导出组件
  imports: [
    BrowserModule,
    AppRoutingModule,
    FormsModule,
    ReactiveFormsModule,
    HttpClientModule,
    HttpClientJsonpModule,
    BrowserAnimationsModule,
    NzButtonModule,
    NzSliderModule,
    NzInputNumberModule,
    NzGridModule,
    NzDrawerModule,
    NzIconModule,
    NzTableModule,
    NzDividerModule,
    NzPopconfirmModule,
    NzModalModule,
    NzFormModule,
    NzInputModule,
    NzSelectModule,
    NzDatePickerModule,
    NzUploadModule,
    NzImageModule
  ],
  providers: [
    { provide: NZ_I18N, useValue: zh_CN }
  ],
  bootstrap: [AppComponent]
})
export class AppModule { }
